<!DOCTYPE html>
<html>
<head>
    <meta charset="UTF-8">
    <title>Document</title>
    <style>
        
    </style>
</head>
<body>
    <div class="box">
        <h1>hello {{ title }}</h1>
        <input type="button" value="修改" @click="change">
    </div>
</body>
<script src="../vue.global.js"></script>
<script>
    
    // console.log(Vue);
    const { createApp } = Vue;

    // 创建一个Vue实例
    const app = createApp({
        data:()=>{
            return {
                title: "Vue"
            }
        },
        methods:{
            change(){
                this.title = "千锋 " + Date.now();
            }
        }
    });

    // 挂载到指定视图
    app.mount(".box");


</script>
</html>